package com.example.common.domain.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.example.common.enums.FileStatus;
import com.example.common.enums.FileType;
import jakarta.persistence.EnumType;
import jakarta.persistence.Enumerated;
import jakarta.persistence.Id;
import jakarta.persistence.Table;
import lombok.Data;

import java.io.Serializable;
import java.sql.Timestamp;

@Data
@Table(name = "resources")
public class Resources {
    @Id
    @TableId(type = IdType.ASSIGN_UUID)
    private String id;
    private String courseId;
    private String teacherId;
    private String name;
    private String url;
    @Enumerated(EnumType.STRING) // 关键注解，存储枚举的 value 字段
    private FileStatus status;      //状态，这个文件的状态
    @Enumerated(EnumType.STRING) // 关键注解，存储枚举的 value 字段
    private FileType type;        //类型，视频还是文件什么的
    private Timestamp createTime;

}
